﻿/// <reference path="../../typings/signalr/signalr.d.ts" />
//interface SignalR {
//    synchronizationHub: {
//        client: {
//            addNewMessageToPage(name: string, message: string)
//        };
//        server: {
//            sync()
//            send(name: string, message: string)
//        };
//    };

interface SignalR {
    synchronizationHub: SynchronizationHub;
}

interface SynchronizationHub {
    server: SynchronizationHubServer;
    client: SynchronizationHubClient;
}

interface SynchronizationHubServer {
    sync();
    //send(msg: ChatMessage): JQueryPromise;
}

interface SynchronizationHubClient {
    addNewMessageToPage: (msg: ChatMessage) => void;
}

interface ChatMessage {
    Name: string;
    Message: string;
}